/** 
* Copyright (C) 2012-2018 ZEEI Inc.All Rights Reserved.
* 项目名称：pls
* 文件名称：PointSynthesizeGisController.java
* 包  名  称：com.zeei.gis.controller
* 文件描述：TODO 请修改文件描述
* 创建日期：2018年1月9日上午10:07:03
* 
* 修改历史
* 1.0 jiangqingpeng 2018年1月9日上午10:07:03 创建文件
*
*/

package com.zeei.gis.controller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import com.zeei.common.annotation.SysLog;
import com.zeei.common.controller.BasicController;
import com.zeei.common.enums.LogType;
import com.zeei.common.vo.ResultDataVO;
import com.zeei.common.vo.ResultRowsVO;
import com.zeei.gis.service.PointSynthesizeGisService;
import com.zeei.gis.vo.DPointListGisVO;
import com.zeei.gis.vo.OutletQueryCondition;
import com.zeei.gis.vo.PointListGisVO;
import com.zeei.gis.vo.PointQuantityByGroupGisVO;
import com.zeei.gis.vo.PointSynthesizeGisVO;
import com.zeei.gis.vo.TwentyFourHourMonitorDataGisVO;
import com.zeei.gis.vo.TwentyFourHourMonitorQueryConditionGisVO;

/**
 * @类型名称：PointSynthesizeGisController
 * @类描述：TODO 废气废水排口综合控制类
 * @功能描述：TODO 废气废水排口综合控制类
 * @创建作者：jiangqingpeng
 */
@Controller
@RequestMapping("/gis/point")
public class PointSynthesizeGisController extends BasicController{

	@Autowired
	PointSynthesizeGisService pointSynthesizeGisService;
	
	@RequestMapping(value="/bycondition", method=RequestMethod.POST)
	@ResponseBody
	@SysLog(text="通过多种条件查询排口信息", type=LogType.View)
	public ResultDataVO<PointSynthesizeGisVO> queryPointSynthesizeByCondition(OutletQueryCondition outletQueryCondition) {
		PointSynthesizeGisVO listPoint = pointSynthesizeGisService.queryPointSynthesizeByCondition(outletQueryCondition);
		return this.createResultDataVO(listPoint, true, "");
	}
	
	@RequestMapping(value="/airpointcode", method=RequestMethod.POST)
	@ResponseBody
	@SysLog(text="通过废气排口编码查询废气排口详情", type=LogType.View)
	public ResultRowsVO<PointListGisVO> queryOutletByPointCode(String pointcode) {
		List<PointListGisVO> listData = pointSynthesizeGisService.queryOutletByPointCode(pointcode);
		return this.createResultRowsVO(listData, true, "", listData.size());
	}
	
	@RequestMapping(value="/waterpointcode", method=RequestMethod.POST)
	@ResponseBody
	@SysLog(text="通过废水排口编码查询废气排口详情", type=LogType.View)
	public ResultRowsVO<DPointListGisVO> queryPointByPointcode(String pointcode){
		List<DPointListGisVO> waterListData = pointSynthesizeGisService.queryPointByPointcode(pointcode);
		return this.createResultRowsVO(waterListData, true, "", waterListData.size());
	}
	
	@RequestMapping(value="/twentyFour", method=RequestMethod.POST)
	@ResponseBody
	@SysLog(text="通过排口编号和当前时间查询实时污染物浓度", type=LogType.View)
	public ResultRowsVO<TwentyFourHourMonitorDataGisVO> queryAirTwentyFourHourMonitorData(TwentyFourHourMonitorQueryConditionGisVO tfhqc) {
		List<TwentyFourHourMonitorDataGisVO> listData = pointSynthesizeGisService.queryAirTwentyFourHourMonitorData(tfhqc);
		return this.createResultRowsVO(listData, true, "", listData.size());
	}
	
	@RequestMapping(value="/city/pointquantity", method=RequestMethod.POST)
	@ResponseBody
	@SysLog(text="查询每个市排口数据", type=LogType.View)
	public ResultRowsVO<PointQuantityByGroupGisVO> queryPointQuantityByAreacodeGroup() {
		List<PointQuantityByGroupGisVO> listData = pointSynthesizeGisService.queryPointQuantityByAreacodeGroup();
		return this.createResultRowsVO(listData, true, "", listData.size());
	}
	
	@RequestMapping(value="/tradecode/pointquantity", method=RequestMethod.POST)
	@ResponseBody
	@SysLog(text="查询每个行业排口数量", type=LogType.View)
	public ResultRowsVO<PointQuantityByGroupGisVO> queryPointQuantityByTradecodeGroup(){
		List<PointQuantityByGroupGisVO> listData = pointSynthesizeGisService.queryPointQuantityByTradecodeGroup();
		return this.createResultRowsVO(listData, true, "", listData.size());
	}
	
	@RequestMapping(value="/controllevel/pointquantity", method=RequestMethod.POST)
	@ResponseBody
	@SysLog(text="查询每个控制级别排口数量", type=LogType.View)
	public ResultRowsVO<PointQuantityByGroupGisVO> queryPointQuantityByControllEvel(){
		List<PointQuantityByGroupGisVO> listData = pointSynthesizeGisService.queryPointQuantityByControllEvel();
		return this.createResultRowsVO(listData, true, "", listData.size());
		
	}
}
